<template>
  <div class="welcome-page" :style="{ backgroundColor: primaryColor }">
    <el-card class="welcome-card" shadow="never">
      <div class="welcome-header">
        <h2 class="title">WELCOME MESSAGE</h2>
      </div>

      <div class="profile-section">
        <el-avatar
            :size="80"
            src="https://cube.elemecdn.com/0/88/03b0d39583f48206768a7534e55bcpng.png"
            class="avatar"
        ></el-avatar>
        <div class="user-info">
          <h3>{{ userName }}</h3>
          <p class="role">{{ userRole }}</p>
        </div>
      </div>

      <p class="welcome-text">
        {{ welcomeText }}
      </p>

      <el-button
          type="primary"
          class="get-started-btn"
          @click="handleGetStarted"
      >
        Get Started
      </el-button>
    </el-card>
  </div>
</template>

<script>
export default {
  name: 'WelcomePage',
  data() {
    return {
      primaryColor: '#a0e6e6',
      userName: 'Alex Chen',
      userRole: 'Frontend Developer',
      welcomeText:
          'Welcome to our platform! We’re excited to have you here. Explore the features and start building amazing things today.'
    }
  },
  methods: {
    handleGetStarted() {
      this.$message.success('Let’s get started!')
      // 可选：this.$router.push('/dashboard')
    }
  }
}
</script>

<style scoped>
.welcome-page {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
  padding: 20px;
  box-sizing: border-box;
}

.welcome-card {
  width: 100%;
  max-width: 700px;
  text-align: center;
  border-radius: 16px;
  padding: 150px;
  box-shadow: 0 8px 24px rgba(52, 199, 216, 0.2);
}

.title {
  font-size: 24px;
  font-weight: 600;
  color: #34c7d8;
  margin-bottom: 20px;
}

.profile-section {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 20px;
}

.avatar {
  margin-bottom: 16px;
  border: 3px solid #34c7d8;
}

.user-info h3 {
  margin: 8px 0 4px;
  font-size: 20px;
  color: #333;
}

.role {
  color: #666;
  font-size: 14px;
}

.welcome-text {
  color: #555;
  line-height: 1.6;
  margin-bottom: 24px;
}

.get-started-btn {
  background-color: #34c7d8 !important;
  border-color: #34c7d8 !important;
}
</style>